package com.song.controller;

import com.song.pojo.Category;
import com.song.pojo.Items;
import com.song.pojo.Notice;
import com.song.service.CategoryService;
import com.song.service.ItemsService;
import com.song.service.NoticeService;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author 宋超
 * HP - the login name of the current user.
 * 2021/6/1 - the current system date.
 * 17:09 - the current system time.
 */
@Controller
public class NoticeInfoController {
    @Resource
    private NoticeService noticeService;

    @RequestMapping("/notice.html")
    public String index(Model model){
       //查询公共信息
        List<Notice> noticeList = noticeService.findAllNoticeList();
        model.addAttribute("noticeList",noticeList);
        return "notice";
    }
}
